﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;

namespace GanoESB
{
    [DataContract]
    public class MessageResponse
    {
        [DataMember]
        public int StateCode { get; set; }

        [DataMember]
        public string StateText { get; set; }

        [DataMember]
        public string Result { get; set; }
    }

    public class MessageResponse<T>
    {
        private int stateCode;
        private string stateText;
        private T result;

        public MessageResponse(int stateCode, string stateText, T result)
        {
            this.stateCode = stateCode;
            this.stateText = stateText;
            this.result = result;
        }

        public int StateCode { get { return stateCode; } }

        public string StateText { get { return stateText; } }

        public T Result { get { return result; } }
    }
}
